package com.eden.manage.mapper;

import com.eden.manage.dto.agent.AgentInviteDto;
import com.eden.manage.model.EdenPlatAgentInvite;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.eden.manage.req.query.AgentInviteQuery;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.util.List;

/**
* @author 98050
* @description 针对表【eden_plat_agent_invite(代理商邀请码表)】的数据库操作Mapper
* @createDate 2023-12-16 20:18:07
* @Entity com.eden.manage.model.EdenPlatAgentInvite
*/
public interface EdenPlatAgentInviteMapper extends BaseMapper<EdenPlatAgentInvite> {

    int countByPage(@Param("query") AgentInviteQuery query);

    List<AgentInviteDto> selectPageList(@Param("query") AgentInviteQuery query);

    int countByEndTime(@Param("platId") Long platId, @Param("agentId") Long agentId
             ,@Param("end")LocalDate end);

    int countByStartTime(@Param("platId") Long platId, @Param("agentId") Long agentId
            ,@Param("start")LocalDate start);

    int updateCodeCancel(@Param("platId") Long platId, @Param("agentId") Long agentId,@Param("id") Long id);
}




